CreateEvent
TheCreateEvent
method creates an Apple event object.
ODSShort CreateEvent (in ODEventClass theAEEventClass, in ODEventID theAEEventID, in ODAddressDesc target, in ODSLong transactionID, out ODAppleEvent theResult);
theAEEventClass
- The event class of the Apple event object to be created.
theAEEventID
- The event ID of the Apple event object to be created.
target
- A reference to the address of the destination part.
transactionID
- A value that uniquely identifies this transaction.
theResult
- A reference to the new Apple event object.
- return value
- The return ID assigned to this event.
DISCUSSION
Your part calls this method instead of theAECreateAppleEvent
method defined by the Apple Event Manager. Your part does not need to specify a return ID for the Apple event object. Instead, OpenDoc assigns a return ID and uses that value to keep track of the sender of the event. ThetransactionID
parameter should be used by your part to identify a related group of Apple event objects and their corresponding replies. If you are creating an event to send to another part, use the message interface'sCreatePartAddrDesc
method to create thetarget
parameter.After this method executes successfully, your part may add whatever data it wants to the resulting Apple event object and then send it using the message interface's
Send
method.EXCEPTIONS
The Apple Event Manager may throw other exceptions.
kODErrOutOfMemory
- There is not enough memory to allocate the event object.
SEE ALSO
TheODEventClass
type (page 925).
TheODEventID
type (page 925).
TheODMessageInterface::CreatePartAddrDesc
method (page 414).
TheODMessageInterface::Send
method (page 416).
TheODAddressDesc
class (page 39).
TheODAppleEvent
class (page 41).
Table 9-1 on page 408 in OpenDoc Programmer's Guide.
"Sending Semantic Events" on page 435 in OpenDoc Programmer's Guide.
Main | Page One | What's New | Apple Computer, Inc. | Find It | Contact Us | Help